/*
 * Copyright (c) 2007 Mockito contributors
 * This program is made available under the terms of the MIT License.
 */

package org.mockito.internal.verification;

import org.mockito.internal.invocation.InvocationImpl;
import org.mockito.internal.util.ObjectMethodsGuru;
import org.mockito.internal.util.collections.ListUtil;
import org.mockito.internal.util.collections.ListUtil.Filter;
import org.mockito.invocation.Invocation;

import java.io.Serializable;
import java.util.LinkedList;
import java.util.List;
import org.mockito.internal.invocation.InvocationMatcher;


public interface RegisteredInvocations {

    public static class RemoveToString implements Filter<Invocation> {
        public boolean isOut(Invocation invocation) {
            return new ObjectMethodsGuru().isToString(invocation.getMethod());
        }
    }

    public static interface Creator extends Serializable {
        RegisteredInvocations newInstance();
    }

    void add(Invocation invocation);

    void removeLast();

    List<Invocation> getAll();

    boolean isEmpty();

    boolean shouldCaptureArgumentsFor(Invocation i);

}
